﻿using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;

namespace DotNetUI.Controls
{
    public class DotNetAzureNavBar : TreeView
    {
        static DotNetAzureNavBar()
        {
            DefaultStyleKeyProperty.OverrideMetadata(typeof(DotNetAzureNavBar), new FrameworkPropertyMetadata(typeof(DotNetAzureNavBar)));
        }

        public static readonly DependencyProperty HeaderProperty = DependencyProperty.Register(nameof(Header), typeof(IIsChecked), typeof(DotNetAzureNavBar));
        public static readonly DependencyProperty FooterProperty = DependencyProperty.Register(nameof(Footer), typeof(IIsChecked), typeof(DotNetAzureNavBar));
        public IIsChecked Header { get => this.GetValue<IIsChecked>(HeaderProperty); set => SetValue(HeaderProperty, value); }
        public IIsChecked Footer { get => this.GetValue<IIsChecked>(FooterProperty); set => SetValue(FooterProperty, value); }
        /// <summary>
        /// 是否选中
        /// </summary>
        public static readonly DependencyProperty IsCheckedProperty = DependencyProperty.Register(nameof(IsChecked), typeof(bool), typeof(DotNetAzureNavBar), new PropertyMetadata(false));
        /// <summary>
        /// 是否选中
        /// </summary>
        public bool IsChecked { get => this.GetValue<bool>(IsCheckedProperty); 
            set => SetValue(IsCheckedProperty, value); }
    }
}
